/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package javaapplication13;

/**
 *
 * @author Irina
 */
public class Exit implements ICommandExecutor {
    private static ICommandExecutor instance;
    @Override
    public void execute (String InputString)
    {
        System.exit(0);
    }
    
    public static ICommandExecutor getInstance()
    {
         if(instance==null)
        {
            instance=new Exit();
        }
        return instance;
    }
}
